﻿using RepositoryPattern.Services;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace RepositoryPattern.Controllers
{
    public class HomeController : Controller
    {
        private ICatalogService _CatalogService;
        public HomeController(ICatalogService catalog)
        {
            _CatalogService = catalog;
        }
        //
        // GET: /Home/
        public ActionResult Index()
        {

            return View(_CatalogService.GetCategories());
        }
    }
}